package com.webRepo.zhengze;

import javax.swing.plaf.SliderUI;

public class ZhengzeTest {

	//匹配
	public static  boolean checkMobileNum(String mobile){
		//18600000001;
		return mobile.matches("1[358]\\d{9}");
	}
	
	//切割
	public static void checkName(){
		// String src="zhangsan     lisi wangwu";
		// //多个空格
		// String[] split = src.split(" +");
		 
//		String src="zhangsan.lisi.wangwu";
//		//正则关键字符分隔
//		String[] split = src.split("\\.");
		
		//组的概念(.)定义了组，\\1引用组
		String src="zhangsan###lisiKKKKwangwu";
		//正则关键字符分隔
		String[] split = src.split("(.)\\1+");
		 for(String value:split){
			 System.out.println(value);
		 }
	}
	
	public static void main(String[] args) {
		System.out.println(checkMobileNum("18600000001"));
		checkName();
	}
}
